<?php
Route::get('test.test', 'mall/Test/test');
/**************注册登录相关*********************/
// 获取登录凭证
Route::get('sign.token', 'mall/Sign/token');
/************** 用户相关 **********************/
// 获取用户信息
Route::get('member.info', 'mall/Member/info');
// 获取一级盟友
Route::get('member.invitation.first', 'mall/Member/invitationFirst');
// 获取二级盟友
Route::get('member.invitation.second', 'mall/Member/invitationSecond');
// 获取一二级盟友数量
Route::get('member.invitation.total', 'mall/Member/invitationTotal');
// 获取邀请二维码
Route::get('member.qr.code', 'mall/Member/QrCode');
// 获取代理商升级条件
Route::get('member.agent.upgrade.conditions', 'mall/Member/agentUpgradeConditions');
/**************** 区域信息相关 *******************/
// 通过pid获取区域列表
Route::get('area.list', 'mall/Area/list');
/**************** 收货地址相关 *******************/
// 创建收货地址
Route::post('address.add', 'mall/Address/add');
// 编辑收货地址
Route::post('address.edit', 'mall/Address/edit');
// 通过ID获取单挑收货地址
Route::get('address.info', 'mall/Address/info');
// 获取收货地址列表
Route::get('address.items', 'mall/Address/items');
// 设为默认
Route::post('address.set.default', 'mall/Address/setDefault');
// 删除地址
Route::post('address.delete', 'mall/Address/delete');
/**************** 商品相关 *******************/
// 获取商品详情
Route::get('goods.detail', 'mall/Goods/detail');
// 根据商品编号获取指定属性的商品信息
Route::get('goods.attach', 'mall/Goods/attach');
// 搜索商品
Route::get('goods.search', 'mall/Goods/search');
// 获取商品列表
Route::get('goods.item', 'mall/Goods/item');
// 通过商品ID获取商品相关的商品列表
Route::get('goods.relevant_item_by_goods_id', 'mall/Goods/relevantItemByGoodsId');
// 获取随机商品
Route::get('goods.rand', 'mall/Goods/rand');
/**************** 应用首页接口 *******************/
Route::get('home.data', 'mall/Index/homeData');
/**************** 收藏相关 *******************/
// 收藏商品
Route::post('collection.goods', 'mall/Collection/goods');
// 取消收藏
Route::post('collection.un.goods', 'mall/Collection/unGoods');
// 获取收藏的商品列表
Route::get('collection.goods.item', 'mall/Collection/goodsItem');
/**************** 购物车相关 *******************/
// 添加商品到购物车
Route::post('cart.add', 'mall/Cart/add');
// 获取购物车商品列表
Route::get('cart.item', 'mall/Cart/item');
// 删除购物车商品
Route::post('cart.del', 'mall/Cart/del');
// 修改购物车商品数量
Route::post('cart.change.number', 'mall/Cart/changeNumber');
// 获取购物车商品数量
Route::get('cart.total', 'mall/Cart/total');
/**************** 订单相关 ********************/
Route::post('order.confirm.goods', 'mall/Order/itemByConfirm');
// 创建订单
Route::post('order.place.an.order', 'mall/Order/placeAnOrder');
// 查询用户订单状态的数量
Route::get('order.status.number', 'mall/Order/statusNumber');
// 通过状态获取订单列表
Route::get('order.item.by.status', 'mall/Order/itemByStatus');
// 通过订单编号获取订单详情
Route::get('order.detail.by.order_no', 'mall/Order/detailByOrderNo');
// 取消订单
Route::post('order.cancel', 'mall/Order/cancel');
// 删除订单
Route::post('order.delete', 'mall/Order/delete');
// 确认收货
Route::post('order.confirm', 'mall/Order/confirm');
/**************** 客服相关 ********************/
// 获取客服微信
Route::get('customer.wechat', 'mall/Customer/wechat');
/**************** 账户相关 ********************/
// 获取账户资金
Route::get('profit.account', 'mall/Profit/account');
// 获取待转入的资金列表
Route::get('profit.wait.record.item', 'mall/Profit/waitRecordItem');
// 获取用户收入记录列表
Route::get('profit.income', 'mall/Profit/income');
// 用户申请提现
Route::post('profit.withdraw', 'mall/Profit/withdraw');
// 获取提现记录
Route::get('profit.withdraw.record', 'mall/Profit/withdrawRecord');
/**************** 支付相关 ********************/
// 支付同步回调
Route::post('pay.wechat.notify.sync', 'mall/Pay/wechatSync');
// 支付异步回调
Route::post('pay.wechat.notify.async', 'mall/PayNotify/wechatAsync');
// 支付
Route::post('pay', 'mall/Pay/pay');
// 代理商升级微信支付
Route::get('pay.agent.upgrade', 'mall/Pay/payUpgradeAgent');
// 代理商升级微信支付同步回调
Route::post('pay.agent.upgrade.sync', 'mall/Pay/wechatUpgradeAgentSync');
// 代理商升级微信支付异步回调
Route::post('pay.agent.upgrade.async', 'mall/PayNotify/wechatUpgradeAgentAsync');